package com.design.pattern.state.config;

import com.design.pattern.state.base.CarState;
import com.design.pattern.state.base.CarStateManager;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.List;

/**
 * @author 王霄
 * @date 2022/3/10 21:21
 */
@Configuration
public class CarStateConfig {

    @Bean
    public CarStateManager carStateManager(List<CarState> carStateList) {
        return new CarStateManager(carStateList);
    }
}
